import QtQuick 1.0
import com.nokia.symbian 1.1
import "pages"
import "js/core.js" as Core

Window {
    id: window

    property variant noteDetails : NoteDetails{}
    property variant notePage : NotePage{}
    property variant quizPage : QuizPage{}
    property variant aboutUsPage: AboutUsPage{}
    property variant aboutTheApp: AboutTheApp{}
    property variant aboutAlfredPage: AboutAlfredPage{}
    property variant aboutCarloPage: AboutCarloPage{}
    property variant aboutRommelPage: AboutRommelPage{}
    property variant topicPage : TopicPage{}
    property variant questionPage : QuestionPage{}
    property variant quizItemPage : QuizItemPage{}

    Image{
        source: "pages/images/background.png"
        anchors.fill: window
    }

    StatusBar {
        id: statusBar
        anchors.top: window.top
    }

    PageStack {
        id: pageStack
        anchors { left: parent.left; right: parent.right
                  top: statusBar.bottom; bottom: toolBar.top }
        toolBar: toolBar
    }

    ToolBar {
        id: toolBar
        anchors.bottom: window.bottom
        tools: ToolBarLayout {
            id: toolBarLayout
        }
    }

    Component.onCompleted: {
        Core.createTable();
        pageStack.push(Qt.resolvedUrl("pages/HomePage.qml"));
    }
}
